<?php 
session_cache_expire(999999999);
if(!isset($_SESSION)) 
{ 
	session_start(); 
}
$lang = $_SESSION['lang'];
if (empty($lang) || $lang == "EN") {
	include "../value/value_en.php";
} else if($lang == "VN") {
	include "../value/value_vn.php";
}
else {
	include "../value/value_kr.php";
}
include '../operations/connection.php';	

$assets=mysql_query("SELECT * FROM assets WHERE id=".$_REQUEST['id_assets']);
$group=0;
$isBorrow=array();
while ($r = mysql_fetch_array($assets)){
	$group=$r['group'];
	$type=$r['type'];
		$isBorrow=array($r['id'],$r['memo']);
}
$group_assets=mysql_query("SELECT g.*,(SELECT COUNT(*) FROM assets a WHERE a.group=g.id ) as count FROM group_assets g ORDER BY g.name;");
$groupassets=array();
while ($r = mysql_fetch_array($group_assets)){
		$groupassets[]=array($r['id'],$r['name'],$r['count']);
}
$type_assets=mysql_query("SELECT t.*,(SELECT COUNT(*) FROM assets a WHERE a.type=t.id ) as count FROM type_assets t ORDER BY t.name;");
$typeassets=array();
while ($r = mysql_fetch_array($type_assets)){
		$typeassets[]=array($r['id'],$r['name'],$r['count']);
}
?>

      


			   <table style=" padding-left:10px;">

							<tr >
								<td  class="tdfirst" style="width: 80px;text-align: center;"><?php echo $l_memo;?></td>
								<td>
									<textarea id="textarea1" name="textarea1" style="width: 370px;text-align: left;font-size: 13px;padding-left: 5px" disabled="disabled"  ><?php echo $isBorrow[1];?></textarea>
								</td>
							</tr >
							
							
					</table>
					
<?php mysql_close($connection);?>